<?php

abstract class Model_Abstract {
	
    public function __get ($name) {
        $match = array();
        if (preg_match('~([a-zA-Z]+)Table~', $name, $match)) {
            return Config::get('db','table_prefix').strtolower($match[1]);
        }else{
        	return $this->$name;
        }
    }
}
?>